< Prev(J) / Next(K) > / View :

Filename: /text/sbasic/shared/03120309.xhp

(section: rtrim) (bookmark: bm_id3154286)
RTrim function

RTrim 関数

RTrim Function [Runtime]
RTrim 関数 [実行時](hd_id3154286.1)

Deletes the spaces at the end of a string expression.
文字列表式の末尾にあるスペース記号を削除します。(par_id3153127.2)

(/section: rtrim)

See also: LTrim Function
次も参照してください:LTrim 関数(par_id3153062.3)

Syntax:
構文:(hd_id3154924.4)

RTrim (Text As String)
RTrim (Text As String)(par_id3154347.5)

Return value:
戻り値:(hd_id3149457.6)

String
文字列(par_id3153381.7)

Parameters:
パラメータ:(hd_id3148798.8)

Text: Any string expression.
Text: 処理をする文字列表現。(par_id3151380.9)

(embed text/sbasic/shared/00000003.xhp#errorcode : linkinfo)

Error Codes

エラーコード(hd_id3152869.37)

(/embed text/sbasic/shared/00000003.xhp#errorcode)

(embed text/sbasic/shared/00000003.xhp#err5 : linkinfo)

5 Invalid procedure call
5 無効なプロシージャー呼び出しです (par_id3150891.41)

(/embed text/sbasic/shared/00000003.xhp#err5)

Example:
例:(hd_id3151041.10)

Sub ExampleSpaces
Sub ExampleSpaces(par_id3148673.11)

Dim sText2 as String,sText as String,sOut as String
Dim sText2 as String,sText as String,sOut as String(par_id3156281.12)

sText2 = " <*Las Vegas*> "
sText2 = " <*Las Vegas*> "(par_id3154125.13)

sOut = "'"+sText2 +"'"+ Chr(13)
sOut = "'"+sText2 +"'"+ Chr(13)(par_id3155131.15)

sText = Ltrim(sText2) REM sText = "<*Las Vegas*> "
sText = Ltrim(sText2) REM sText = "<*Las Vegas*> "(par_id3161833.16)

sOut = sOut + "'"+sText +"'" + Chr(13)
sOut = sOut + "'"+sText +"'" + Chr(13)(par_id3147317.17)

sText = Rtrim(sText2) REM sText = " <*Las Vegas*>"
sText = Rtrim(sText2) REM sText = " <*Las Vegas*>"(par_id3151112.18)

sOut = sOut +"'"+ sText +"'" + Chr(13)
sOut = sOut + "'"+sText +"'" + Chr(13)(par_id3149664.19)

sText = Trim(sText2) REM sText = "<*Las Vegas*>"
sText = Trim(sText2) REM sText = " <*Las Vegas*> "(par_id3152576.20)

sOut = sOut +"'"+ sText +"'"
sOut = sOut +"'"+ sText +"'"(par_id3153729.21)

MsgBox sOut
MsgBox sOut(par_id3145749.22)

end sub
end sub(par_id3146922.23)


< Prev / Next >